<script>
export default {
name: 'Login',
data() {
return {
username: '',
password: ''
}

},
methods: {
login() {
alert('登录成功')
  console.log(this.username, this.password)
}
}
}
</script>
<template>
<h1>登录</h1>
<form>
<p>用户名：
<input type="text" name="username"></p>
<p>密码：<input type="password" name="password"></input></p>
<p><button @click="login">登录</button></p>
</form>
</template>



<style scoped>
</style>